package com.hand.test.config;/**
 * @author Estelle@앙수청
 * @date 2019/7/20 16:58
 */

import com.hand.test.filter.PermissionFilter;
import org.springframework.boot.web.servlet.FilterRegistrationBean;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 *  @author Estelle@앙수청
 *  @date 2019/7/20 16:58
 */
//@Configuration
public class FilterConfig {

    /**
     * 配置过滤器参数
     * @return
     */
    @Bean
    public FilterRegistrationBean filterRegistrationBean(){
        FilterRegistrationBean bean = new FilterRegistrationBean();
        bean.setFilter(new PermissionFilter());
        bean.addUrlPatterns("/*");
        return bean;
    }
}
